package com.hy.mydesktop.shared.business;

import java.util.ArrayList ;
import java.util.HashMap ;
import java.util.List ;
import java.util.Map ;

import com.extjs.gxt.ui.client.data.BaseModel ;
import com.extjs.gxt.ui.client.data.ModelData ;
import com.hy.mydesktop.client.component.meta.GridColumnConfigModel;
import com.hy.mydesktop.client.component.mvc.event.EventStructureMetaModel;
import com.hy.mydesktop.client.component.type.ComponentControllerEnum;
import com.hy.mydesktop.client.component.type.ComponentTypeEnum;
import com.hy.mydesktop.shared.persistence.domain.gxt.GxtComponentControllerMetaModel;
import com.hy.mydesktop.shared.persistence.domain.gxt.GxtComponentControllerMetaNodeModel;
import com.hy.mydesktop.shared.persistence.domain.gxt.GxtComponentMetaModel;
import com.hy.mydesktop.shared.persistence.domain.gxt.GxtComponentMetaNodeModel;
import com.hy.mydesktop.shared.persistence.domain.gxt.constant.MetaDataConstants;


public class DesktopService
{

	//创建桌面快捷方式的代码	
	private GxtComponentControllerMetaModel createDynamicDesktopController3() {

		Map<String , Object> desktopController=new HashMap<String, Object>();
//		desktopController.put("component_controller_model_type", ComponentControllerEnum.DESKTOP_CONTROL_MODEL);
		desktopController.put("component_controller_model_type_index", ComponentControllerEnum.DESKTOP_CONTROLLOR_MODEL.ordinal());
		List<String> codes1 = new ArrayList<String>();
		codes1.add("0003");
		codes1.add("0002");
		codes1.add("0005");
		desktopController.put("registereventtypes", codes1);
		desktopController.put("id", "desktopController");
		GxtComponentControllerMetaNodeModel node=new GxtComponentControllerMetaNodeModel(desktopController,1,6);
		
		Map<String , Object> shortcutController=new HashMap<String, Object>();
//		shortcutController.put("component_controller_model_type", ComponentControllerEnum.SHORTCUT_CONTROLLER_MODEL);
		shortcutController.put("component_controller_model_type_index", ComponentControllerEnum.SHORTCUT_CONTROLLER_MODEL.ordinal());
		List<String> codes2 = new ArrayList<String>();
		codes2.add("0003");
		codes2.add("0002");
		codes2.add("0005");
		shortcutController.put("registereventtypes", codes2);
		shortcutController.put("id", "shortcutController01");
		shortcutController.put("viewdata", "shortcut_viewData_init_01");	
		shortcutController.put(MetaDataConstants.GXT_COMPONENT__METANODEMODEL, this.getShortcutGxtComponentMetaNodeModel());		
		GxtComponentControllerMetaNodeModel node2=new GxtComponentControllerMetaNodeModel(shortcutController,2,3);
		
		
		
		Map<String , Object> desktopMeunItemController=new HashMap<String, Object>();
//		desktopMeunItemController.put("component_controller_model_type", ComponentControllerEnum.DESKTOP_MENUITEM_CONTROLLER_MODEL);
		desktopMeunItemController.put("component_controller_model_type_index", ComponentControllerEnum.DESKTOP_MENUITEM_CONTROLLER_MODEL.ordinal());
		List<String> codes3 = new ArrayList<String>();
		codes3.add("0003");
		codes3.add("0002");
		codes3.add("0005");
		desktopMeunItemController.put("registereventtypes", codes3);
		desktopMeunItemController.put("id", "desktopMeunItemController01");
		desktopMeunItemController.put("viewdata", "desktopmenuitem_viewData_init_01");		
		desktopMeunItemController.put(MetaDataConstants.GXT_COMPONENT__METANODEMODEL, this.getDesktopMeunItemMetaNodeModel());		

		GxtComponentControllerMetaNodeModel node3=new GxtComponentControllerMetaNodeModel(desktopMeunItemController,4,5);
		
		
		
		List<GxtComponentControllerMetaNodeModel> list=new ArrayList<GxtComponentControllerMetaNodeModel>();
		list.add(node);
		list.add(node2);
		list.add(node3);
		

		GxtComponentControllerMetaModel gxtComponentMetaModel=new GxtComponentControllerMetaModel(list);
		
		
		
		
		return gxtComponentMetaModel;
		

	}
	
	

	private GxtComponentMetaNodeModel getDesktopMeunItemMetaNodeModel() {
		Map<String, Object> map2=new HashMap<String, Object>();
		//map2.put("component_model_type", ComponentTypeEnum.SHORTCUT_MODEL);
		map2.put("component_model_type_index", ComponentTypeEnum.DESKTOP_MENUITEM_MODEL.ordinal());
		//TODO map2.put("appEventType", AppEvents.DESKTOP_SHORTCUT_ONCLICK_INIT);
			Map<String,Object> RegisterEventTypeDatas = new HashMap<String, Object>();
			//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
			/**
			 * 00_01_02为特征码
			 * 或者是 控制器的唯一标识
			 */
				Map<String,Object> oneRegisterEventTypeData = new HashMap<String, Object>();
					EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
					eventStructureMetaModel.setControllerId("shortcutController01");
					eventStructureMetaModel.setRootControllerId("desktopController");
					eventStructureMetaModel.setResponseModeId("00_01_02");
				oneRegisterEventTypeData.put("eventstructuremetamodel", eventStructureMetaModel);
				
					Map<String,Object> oneDispacherEventTypeData = new HashMap<String, Object>();
						EventStructureMetaModel subEventStructureMetaModel = new EventStructureMetaModel();
						subEventStructureMetaModel.setControllerId("1_1_windowController_Organisation");
						subEventStructureMetaModel.setRootControllerId("1_1_windowController_Organisation");
					oneDispacherEventTypeData.put("eventstructuremetamodel", subEventStructureMetaModel);
					oneDispacherEventTypeData.put("count", 7);
				oneRegisterEventTypeData.put("dispachereventtype", "0007");
				
			RegisterEventTypeDatas.put("0003", oneRegisterEventTypeData);
			//codes1.add("0002");
		map2.put("registereventtypes", RegisterEventTypeDatas);
			Map<String,Object> dispacherEventTypeDatas = new HashMap<String, Object>();
			dispacherEventTypeDatas.put("0007", oneDispacherEventTypeData);
		map2.put("dispachereventtypes", dispacherEventTypeDatas);
		//map2.put("icon", "user");
		//map2.put("icon", "extanim32");
		map2.put("text", "Rpc   -----LoginView----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
		GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
		return node2;
	}

	
	
	

	private GxtComponentMetaNodeModel getShortcutGxtComponentMetaNodeModel() {
		Map<String, Object> map2=new HashMap<String, Object>();
		//map2.put("component_model_type", ComponentTypeEnum.SHORTCUT_MODEL);
		map2.put("component_model_type_index", ComponentTypeEnum.SHORTCUT_MODEL.ordinal());
		//TODO map2.put("appEventType", AppEvents.DESKTOP_SHORTCUT_ONCLICK_INIT);
			Map<String,Object> RegisterEventTypeDatas = new HashMap<String, Object>();
			//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
			/**
			 * 00_01_02为特征码
			 * 或者是 控制器的唯一标识
			 */
				Map<String,Object> oneRegisterEventTypeData = new HashMap<String, Object>();
					EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
					eventStructureMetaModel.setControllerId("shortcutController01");
					eventStructureMetaModel.setRootControllerId("desktopController");
					eventStructureMetaModel.setResponseModeId("00_01_02");
				oneRegisterEventTypeData.put("eventstructuremetamodel", eventStructureMetaModel);
				
					Map<String,Object> oneDispacherEventTypeData = new HashMap<String, Object>();
						EventStructureMetaModel subEventStructureMetaModel = new EventStructureMetaModel();
						subEventStructureMetaModel.setControllerId("1_1_windowController_Organisation");
						subEventStructureMetaModel.setRootControllerId("1_1_windowController_Organisation");
					oneDispacherEventTypeData.put("eventstructuremetamodel", subEventStructureMetaModel);
					oneDispacherEventTypeData.put("count", 7);
				oneRegisterEventTypeData.put("dispachereventtype", "0007");
				
			RegisterEventTypeDatas.put("0003", oneRegisterEventTypeData);
			//codes1.add("0002");
		map2.put("registereventtypes", RegisterEventTypeDatas);
			Map<String,Object> dispacherEventTypeDatas = new HashMap<String, Object>();
			dispacherEventTypeDatas.put("0007", oneDispacherEventTypeData);
		map2.put("dispachereventtypes", dispacherEventTypeDatas);
		//map2.put("icon", "user");
		//map2.put("icon", "extanim32");
		map2.put("text", "Rpc   -----LoginView----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
		GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
		return node2;
	}

	
	
	public List<GxtComponentControllerMetaModel> validateLogin0 ( BaseModel	baseModel) {
		
		System.err.println("DepartmentServices is running ...............................");
		List<GxtComponentControllerMetaModel> list=new ArrayList<GxtComponentControllerMetaModel>();
		
		//list.add(gxtComponentMetaModel);
		list.add(this.createDynamicDesktopController3());
		//list.add(this.createDynamicWindowController22());
			
	
		return list;
	}
	
	private GxtComponentMetaModel createDynamicWindowController22() {


		
		
		//窗口控制器
		Map<String , Object> windowController=new HashMap<String, Object>();
//		windowController.put("component_controller_model_type", ComponentControllerEnum.WINDOW_CONTROLLER_MODEL);
		windowController.put("component_controller_model_type_index", ComponentControllerEnum.WINDOW_CONTROLLER_MODEL.ordinal());
		List<String> codes1 = new ArrayList<String>();
		codes1.add("0301");		
		codes1.add("0401");
		codes1.add("0007");
		codes1.add("0008");
		codes1.add("0010");
		
		windowController.put("id", "1_1_windowController_Organisation");
		windowController.put("registereventtypes", codes1);
		windowController.put("viewdata", "window_viewData_init_02");		
		windowController.put("gxtcomponentmetanodemodel", this.getWindowGxtComponentMetaNodeModel());		
		GxtComponentMetaNodeModel node=new GxtComponentMetaNodeModel(windowController,1,42);
		
		//内容面板控制器
		Map<String , Object> contentPanelController=new HashMap<String, Object>();
//		contentPanelController.put("component_controller_model_type", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL);
		contentPanelController.put("component_controller_model_type_index", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes2 = new ArrayList<String>();
		codes2.add("0301");
		codes2.add("0401");
		codes2.add("0007");
		codes2.add("0008");
		contentPanelController.put("registereventtypes", codes2);				
		contentPanelController.put("id", "2_1_contentPanelController_Organisation");				
		contentPanelController.put("viewdata", "contentPanel_viewData_init_01");
		contentPanelController.put("gxtcomponentmetanodemodel", this.getContentPanelGxtComponentMetaNodeModel());		

		GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(contentPanelController,2,41);
		
		//菜单栏控制器
		Map<String , Object> menuBarController=new HashMap<String, Object>();
//		menuBarController.put("component_controller_model_type", ComponentControllerEnum.MENUBAR_CONTROLLER_MODEL);
		menuBarController.put("component_controller_model_type_index", ComponentControllerEnum.MENUBAR_CONTROLLER_MODEL.ordinal());
		List<String> codes3 = new ArrayList<String>();
		codes3.add("0301");
		codes3.add("0401");
		codes3.add("0007");
		codes3.add("0008");
		menuBarController.put("registereventtypes", codes3);
		menuBarController.put("id", "3_1_menuBarController_Organisation");
		menuBarController.put("viewdata", "menuBar_viewData_init_01");		
	//	menuBarController.put("gxtcomponentmetanodemodel", this.getMenuBarGxtComponentMetaNodeModel2());		
		GxtComponentMetaNodeModel node3=new GxtComponentMetaNodeModel(menuBarController,3,4);
		
		
		//工具栏控制器
		Map<String , Object> toolBarController=new HashMap<String, Object>();
//		toolBarController.put("component_controller_model_type", ComponentControllerEnum.TOOLBAR_CONTROLLER_MODEL);
		toolBarController.put("component_controller_model_type_index", ComponentControllerEnum.TOOLBAR_CONTROLLER_MODEL.ordinal());
		List<String> codes4 = new ArrayList<String>();
	    codes4.add("0301");
		codes4.add("0401");
		codes4.add("0007");
		codes4.add("0008");
		toolBarController.put("registereventtypes", codes4);
		toolBarController.put("id", "3_1_toolBarController_Organisation");
		toolBarController.put("viewdata", "toolBar_viewData_init_01");		
		toolBarController.put("gxtcomponentmetanodemodel", this.getToolBarGxtComponentMetaNodeModel2());		
		GxtComponentMetaNodeModel node4=new GxtComponentMetaNodeModel(toolBarController,5,6);
		
		
		
		//提交面板控制器
		Map<String, Object> sumFormPanelController=new HashMap<String, Object>();
//		sumFormPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMPANEL_CONTROLLER_MODEL);
		sumFormPanelController.put("component_controller_model_type_index", ComponentControllerEnum.FORMPANEL_CONTROLLER_MODEL.ordinal());
//		sumFormPanelController.put("component_controller_model_type_index", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes45 = new ArrayList<String>();
		codes45.add("0301");
		codes45.add("0401");
		codes45.add("0007");
		codes45.add("0008");
		sumFormPanelController.put("registereventtypes", codes45);
		sumFormPanelController.put("id", "3_1_sumFormPanelController_Organisation");
		sumFormPanelController.put("controllerdata", "sumFormPanel_controllerdata_init_01");		
		sumFormPanelController.put("viewdata", "sumFormPanel_viewData_init_01");		
		sumFormPanelController.put("gxtcomponentmetanodemodel",  this.getSumFormPanelGxtComponentMetaNodeModel());		
		//sumFormPanelController.put("gxtcomponentmetanodemodel", this.getContentPanelGxtComponentMetaNodeModel());		

		GxtComponentMetaNodeModel node45=new GxtComponentMetaNodeModel(sumFormPanelController, 7, 40);
		
		
		
		
		
		
		
		Map<String , Object> tabPanelController=new HashMap<String, Object>();
//		textFieldController.put("component_controller_model_type", ComponentControllerEnum.GRIDSETMODULES_CONTROLLER_MODEL);
		tabPanelController.put("component_controller_model_type_index", ComponentControllerEnum.TABPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes5 = new ArrayList<String>();
		codes5.add("0401"); 
		codes5.add("0301"); 
		codes5.add("0007");
		codes5.add("0008");
		tabPanelController.put("registereventtypes", codes5);
		
		tabPanelController.put("id", "4_1_tabPanelController_Organisation");
		tabPanelController.put("viewdata", "textField_viewData_init_01");	
		tabPanelController.put("gxtcomponentmetanodemodel", this.getTabPanelGxtComponentMetaNodeModel());		
		GxtComponentMetaNodeModel node5=new GxtComponentMetaNodeModel(tabPanelController,8,39);
		//部门基本信息tab页
		Map<String , Object> tabItemController01=new HashMap<String, Object>();
//		textFieldController.put("component_controller_model_type", ComponentControllerEnum.GRIDSETMODULES_CONTROLLER_MODEL);
		tabItemController01.put("component_controller_model_type_index", ComponentControllerEnum.TABITEM_CONTROLLER_MODEL.ordinal());
		List<String> codes5_1 = new ArrayList<String>();
		codes5_1.add("0401"); 
		codes5_1.add("0301"); 
		codes5_1.add("0007");
		codes5_1.add("0008");
		tabItemController01.put("registereventtypes", codes5_1);
		tabItemController01.put("id", "5_1_tabItemController01_Organisation");
		tabItemController01.put("viewdata", "textField_viewData_init_01");	
		tabItemController01.put("gxtcomponentmetanodemodel", this.getTabItemGxtComponentMetaNodeModel1());		
		GxtComponentMetaNodeModel node6=new GxtComponentMetaNodeModel(tabItemController01,9,30);
		//部门联系方式tab页
		Map<String , Object> tabItemController02=new HashMap<String, Object>();
//		textFieldController.put("component_controller_model_type", ComponentControllerEnum.GRIDSETMODULES_CONTROLLER_MODEL);
		tabItemController02.put("component_controller_model_type_index", ComponentControllerEnum.TABITEM_CONTROLLER_MODEL.ordinal());
		List<String> codes5_1_1 = new ArrayList<String>();
		codes5_1_1.add("0401"); 
		codes5_1_1.add("0301"); 
		codes5_1_1.add("0007");
		codes5_1_1.add("0008");
		tabItemController02.put("registereventtypes", codes5_1_1);
		tabItemController02.put("id", "5_2_tabItemController02_Organisation");
		tabItemController02.put("viewdata", "textField_viewData_init_01");	
		tabItemController02.put("gxtcomponentmetanodemodel", this.getTabItemGxtComponentMetaNodeModel2());	
		GxtComponentMetaNodeModel node7=new GxtComponentMetaNodeModel(tabItemController02,31,38);
		
		
		

		//部门基本信息内容面板控制器1
		Map<String , Object> contentPanelController1=new HashMap<String, Object>();
//		contentPanelController.put("component_controller_model_type", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL);
		contentPanelController1.put("component_controller_model_type_index", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes6 = new ArrayList<String>();
		codes6.add("0301");
		codes6.add("0401");
		codes6.add("0007");
		codes6.add("0008");
		contentPanelController1.put("registereventtypes", codes6);				
		contentPanelController1.put("id", "6_1_contentPanelController_Organisation");				
		contentPanelController1.put("viewdata", "contentPanel_viewData_init_01");
		contentPanelController1.put("gxtcomponentmetanodemodel", this.getContentPanelGxtComponentMetaNodeModel1());	
		
		GxtComponentMetaNodeModel node8=new GxtComponentMetaNodeModel(contentPanelController1,10,19);
		

		//部门基本信息内容面板控制器2
		Map<String , Object> contentPanelController2=new HashMap<String, Object>();
//		contentPanelController.put("component_controller_model_type", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL);
		contentPanelController2.put("component_controller_model_type_index", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes7 = new ArrayList<String>();
		codes7.add("0301");
		codes7.add("0401");
		codes7.add("0007");
		codes7.add("0008");
		contentPanelController2.put("registereventtypes", codes7);				
		contentPanelController2.put("id", "6_2_contentPanelController_Organisation");				
		contentPanelController2.put("viewdata", "contentPanel_viewData_init_01");
		contentPanelController2.put("gxtcomponentmetanodemodel", this.getContentPanelGxtComponentMetaNodeModel2());	
		
		GxtComponentMetaNodeModel node9=new GxtComponentMetaNodeModel(contentPanelController2,20,29);
		
		

		//部门联系方式内容面板控制器
		Map<String , Object> contentPanelController3=new HashMap<String, Object>();
//		contentPanelController.put("component_controller_model_type", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL);
		contentPanelController3.put("component_controller_model_type_index", ComponentControllerEnum.CONTENTPANEL_CONTROLLER_MODEL.ordinal());
		List<String> codes8 = new ArrayList<String>();
		codes8.add("0301");
		codes8.add("0401");
		codes8.add("0007");
		codes8.add("0008");
		contentPanelController3.put("registereventtypes", codes8);				
		contentPanelController3.put("id", "6_3_contentPanelController_Organisation");				
		contentPanelController3.put("viewdata", "contentPanel_viewData_init_01");
		contentPanelController3.put("gxtcomponentmetanodemodel", this.getContentPanelGxtComponentMetaNodeModel3());	
		
		GxtComponentMetaNodeModel node10=new GxtComponentMetaNodeModel(contentPanelController3,32,37);
		
		
		
		
		
		//名称  文本框控制器
		Map<String , Object> textFieldController_6_1=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		textFieldController_6_1.put("component_controller_model_type_index", ComponentControllerEnum.TEXTFIELD_CONTROLLER_MODEL.ordinal());
		List<String> codes6_3 = new ArrayList<String>();
		codes6_3.add("0301");
		codes6_3.add("0401");
		codes6_3.add("0007");
		codes6_3.add("0008");
		textFieldController_6_1.put("registereventtypes", codes6_3);
		textFieldController_6_1.put("id", "7_1_textFieldController_Organisation");
		textFieldController_6_1.put("controllerdata", "textFieldController_5_2_3_controllerdata_init_01");		
		textFieldController_6_1.put("viewdata", "textFieldController_5_2_3_viewData_init_01");		
		textFieldController_6_1.put("gxtcomponentmetanodemodel",  this.getTextFieldGxtComponentMetaNodeModelnode7_1());		
		GxtComponentMetaNodeModel node11=new GxtComponentMetaNodeModel(textFieldController_6_1,11,12);

		
		
		//负责人职位下拉框控制器 
		Map<String , Object> ComboBoxController=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		ComboBoxController.put("component_controller_model_type_index", ComponentControllerEnum.COMBOBOX_CONTROLLER_MODEL.ordinal());
		List<String> codes6_2 = new ArrayList<String>();
		codes6_2.add("0301");
		codes6_2.add("0401");
		codes6_2.add("0007");
		codes6_2.add("0008");
		ComboBoxController.put("registereventtypes", codes6_2);
		ComboBoxController.put("id", "7_1_ComboBoxController_UnitConversionRate");
		ComboBoxController.put("controllerdata", "comboBoxController_5_1_2_controllerdata_init_01");		
		ComboBoxController.put("viewdata", "comboBoxController_5_1_2_viewData_init_01");		
		ComboBoxController.put("gxtcomponentmetanodemodel",  this.getComboBoxGxtComponentMetaNodeModelnode7_1());		
		GxtComponentMetaNodeModel node12=new GxtComponentMetaNodeModel(ComboBoxController,13,14);
		
		
		
		
		//具体地址 文本框控制器
		Map<String , Object> textFieldController_6_2=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		textFieldController_6_2.put("component_controller_model_type_index", ComponentControllerEnum.TEXTFIELD_CONTROLLER_MODEL.ordinal());
		List<String> codes6_4 = new ArrayList<String>();
		codes6_4.add("0301");
		codes6_4.add("0401");
		codes6_4.add("0007");
		codes6_4.add("0008");
		textFieldController_6_2.put("registereventtypes", codes6_4);
		textFieldController_6_2.put("id", "7_2_textFieldController_Organisation");
		textFieldController_6_2.put("controllerdata", "textFieldController_5_2_3_controllerdata_init_01");		
		textFieldController_6_2.put("viewdata", "textFieldController_5_2_3_viewData_init_01");		
		textFieldController_6_2.put("gxtcomponentmetanodemodel",  this.getTextFieldGxtComponentMetaNodeModelnode7_2());		
		GxtComponentMetaNodeModel node13=new GxtComponentMetaNodeModel(textFieldController_6_2,15,16);

		
		//描述 文本区域控制器
		Map<String , Object> textAreaController_6_1=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		textAreaController_6_1.put("component_controller_model_type_index", ComponentControllerEnum.TEXTAREA_CONTROLLER_MODEL.ordinal());
		List<String> codes6_5 = new ArrayList<String>();
		codes6_5.add("0301");
		codes6_5.add("0401");
		codes6_5.add("0007");
		codes6_5.add("0008");
		textAreaController_6_1.put("registereventtypes", codes6_5);
		textAreaController_6_1.put("id", "7_1_textAreaController_Organisation");
		textAreaController_6_1.put("controllerdata", "textAreaController_5_1_1_controllerdata_init_01");		
		textAreaController_6_1.put("viewdata", "textFieldController_5_1_1_viewData_init_01");		
		textAreaController_6_1.put("gxtcomponentmetanodemodel",  this.getTextAreaGxtComponentMetaNodeModelnode7_1());
		GxtComponentMetaNodeModel node14=new GxtComponentMetaNodeModel(textAreaController_6_1,17,18);
		
		
		//简称文本框控制器
		Map<String , Object> textFieldController_6_3=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		textFieldController_6_3.put("component_controller_model_type_index", ComponentControllerEnum.TEXTFIELD_CONTROLLER_MODEL.ordinal());
		List<String> codes6_6 = new ArrayList<String>();
		codes6_6.add("0301");
		codes6_6.add("0401");
		codes6_6.add("0007");
		codes6_6.add("0008");
		textFieldController_6_3.put("registereventtypes", codes6_6);
		textFieldController_6_3.put("id", "7_3_textFieldController_Organisation");
		textFieldController_6_3.put("controllerdata", "textFieldController_5_2_3_controllerdata_init_01");		
		textFieldController_6_3.put("viewdata", "textFieldController_5_2_3_viewData_init_01");		
		textFieldController_6_3.put("gxtcomponentmetanodemodel",  this.getTextFieldGxtComponentMetaNodeModelnode7_3());		
		GxtComponentMetaNodeModel node15=new GxtComponentMetaNodeModel(textFieldController_6_3,21,22);

		

		//上级组织下拉框控制器 
		Map<String , Object> ComboBoxController2=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		ComboBoxController2.put("component_controller_model_type_index", ComponentControllerEnum.COMBOBOX_CONTROLLER_MODEL.ordinal());
		List<String> codes6_7 = new ArrayList<String>();
		codes6_7.add("0301");
		codes6_7.add("0401");
		codes6_7.add("0007");
		codes6_7.add("0008");
		ComboBoxController2.put("registereventtypes", codes6_7);
		ComboBoxController2.put("id", "7_2_ComboBoxController_Organisation");
		ComboBoxController2.put("controllerdata", "comboBoxController_5_1_2_controllerdata_init_01");		
		ComboBoxController2.put("viewdata", "comboBoxController_5_1_2_viewData_init_01");		
		ComboBoxController2.put("gxtcomponentmetanodemodel",  this.getComboBoxGxtComponentMetaNodeModelnode7_2());		
		GxtComponentMetaNodeModel node16=new GxtComponentMetaNodeModel(ComboBoxController2,23,24);
		
		
		//成立日期
		Map<String , Object> DatedateFieldController=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		DatedateFieldController.put("component_controller_model_type_index", ComponentControllerEnum.DATEFIELD_CONTROLLER_MODEL.ordinal());
		List<String> codes5_2_2 = new ArrayList<String>();
		codes5_2_2.add("0301");
		codes5_2_2.add("0401");
		codes5_2_2.add("0007");
		codes5_2_2.add("0008");
		DatedateFieldController.put("registereventtypes", codes5_2_2);
		DatedateFieldController.put("id", "7_1_DatedateFieldController_Organisation");
		DatedateFieldController.put("controllerdata", "dateFieldController_5_2_2_controllerdata_init_01");		
		DatedateFieldController.put("viewdata", "dateFieldController_5_2_2_viewData_init_01");		
		DatedateFieldController.put("gxtcomponentmetanodemodel",  this.getDateFieldGxtComponentMetaNodeModel1());		
		GxtComponentMetaNodeModel node17=new GxtComponentMetaNodeModel(DatedateFieldController,25,26);
		
		

		//备注 文本区域控制器
		Map<String , Object> textAreaController_6_2=new HashMap<String, Object>();
//		formPanelController.put("component_controller_model_type", ComponentControllerEnum.FORMSET_MODULE_CONTROLLER_MODEL);
		textAreaController_6_2.put("component_controller_model_type_index", ComponentControllerEnum.TEXTAREA_CONTROLLER_MODEL.ordinal());
		List<String> codes6_8 = new ArrayList<String>();
		codes6_8.add("0301");
		codes6_8.add("0401");
		codes6_8.add("0007");
		codes6_8.add("0008");
		textAreaController_6_2.put("registereventtypes", codes6_8);
		textAreaController_6_2.put("id", "7_2_textAreaController_Organisation");
		textAreaController_6_2.put("controllerdata", "textAreaController_5_1_1_controllerdata_init_01");		
		textAreaController_6_2.put("viewdata", "textFieldController_5_1_1_viewData_init_01");		
		textAreaController_6_2.put("gxtcomponentmetanodemodel",  this.getTextAreaGxtComponentMetaNodeModelnode7_2());
		GxtComponentMetaNodeModel node18=new GxtComponentMetaNodeModel(textAreaController_6_2,27,28);
		
		
		
		Map<String , Object> gridController=new HashMap<String, Object>();
//		gridController.put("component_controller_model_type", ComponentControllerEnum.GRIDSETMODULES_CONTROLLER_MODEL);
		gridController.put("component_controller_model_type_index", ComponentControllerEnum.GRIDSETMODULES_CONTROLLER_MODEL.ordinal());
		List<String> codes9 = new ArrayList<String>();
		codes9.add("0401"); 
		codes9.add("0301"); 
		codes9.add("0007");
		codes9.add("0008");
		gridController.put("registereventtypes", codes9);
		gridController.put("id", "7_1_gridController_Organisation");
		gridController.put("viewdata", "textField_viewData_init_01");	
		gridController.put("gxtcomponentmetanodemodel", this.getGridSetModuleGxtComponentMetaNodeModel());		
		GxtComponentMetaNodeModel node19=new GxtComponentMetaNodeModel(gridController,33,36);
		
		Map<String , Object> dataLoadController=new HashMap<String, Object>();
//		dataLoadController.put("component_controller_model_type", ComponentControllerEnum.GRID_DATALOAD_CONTROLLER_MODEL);
		dataLoadController.put("component_controller_model_type_index", ComponentControllerEnum.GRID_DATALOAD_CONTROLLER_MODEL.ordinal());
		List<String> codes12222 = new ArrayList<String>();
		codes12222.add("0301");		
		codes12222.add("0201");
		codes12222.add("0401");
		
		//加载数据控制器id
		dataLoadController.put("id", "8_1_dataLoadController_Organisation");
		dataLoadController.put("registereventtypes", codes12222);
		//dataLoadController.put("gxtcomponentmetanodemodel", codes12222);
		//windowController.put("viewdata", "window_viewData_init_01");		
		GxtComponentMetaNodeModel node20=new GxtComponentMetaNodeModel(dataLoadController,34,35);
		
		
		List<GxtComponentMetaNodeModel> list=new ArrayList<GxtComponentMetaNodeModel>();
		list.add(node);
		list.add(node2);
		list.add(node3);
		list.add(node4);
		list.add(node45);
		list.add(node5);
		list.add(node6);
		list.add(node7);
		list.add(node8);
		list.add(node9);
		list.add(node10);
		
		list.add(node11);
		list.add(node12);
		list.add(node13);
		list.add(node14);
		list.add(node15);
		list.add(node16);
		list.add(node17);
		list.add(node18);
		list.add(node19);
		list.add(node20);
		GxtComponentMetaModel gxtComponentMetaModel=new GxtComponentMetaModel(list);
		return gxtComponentMetaModel;
	}
	
	
	
	
	
	
	
	
	/**
	 * 模拟从后台传过来的关于Window控件的元模型信息
	 */
	private GxtComponentMetaNodeModel getWindowGxtComponentMetaNodeModel( ) {
		Map<String, Object> map2=new HashMap<String, Object>();
//		map2.put("component_model_type", ComponentTypeEnum.WINDOW_MODEL);
		map2.put("component_model_type_index", ComponentTypeEnum.WINDOW_MODEL.ordinal());
		map2.put("title", "部门设置");
		map2.put("width", 800);
		map2.put("hight", 550);
		map2.put("id", "01_01_windowGxtComponent_Organisation");
		map2.put("resizable", false);
		map2.put("maxmizable", false);
		map2.put("minmizable", true);
		map2.put("layout", ComponentTypeEnum.FITLAYOUT_MODEL.ordinal());
		GxtComponentMetaModel gxtComponentMetaModel = new GxtComponentMetaModel();
		GxtComponentMetaNodeModel gxtComponentMetaNodeModel=new GxtComponentMetaNodeModel(map2);
		                   
		return gxtComponentMetaNodeModel;
		
	}
	
	
	private GxtComponentMetaNodeModel getContentPanelGxtComponentMetaNodeModel() {
		Map<String, Object> map2=new HashMap<String, Object>();
		//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
		map2.put("component_model_type_index", ComponentTypeEnum.CONTENTPANEL_MODEL.ordinal());
		map2.put("headervisible", false);	
		map2.put("id", "02_01_contentPanelGxtComponent_Organisation");	
		map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
		GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
		return node2;
	}
	
	private GxtComponentMetaNodeModel getToolBarGxtComponentMetaNodeModel2() {
		
		
	 	Map<String, Object> button01 = new HashMap<String, Object>();
	    button01.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());   
	    button01.put("text", "新建");
		  //TODO map2.put("appEventType", AppEvents.DESKTOP_SHORTCUT_ONCLICK_INIT);
			Map<String,Object> codes2 = new HashMap<String, Object>();
			//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
			/**
			 * 00_01_02为特征码
			 * 或者是 控制器的唯一标识
			 */
				Map<String,Object> oneRegisterEventTypeData = new HashMap<String, Object>();
					EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
					eventStructureMetaModel.setControllerId("windowController2");
					eventStructureMetaModel.setRootControllerId("windowController2");
				oneRegisterEventTypeData.put("eventstructuremetamodel", eventStructureMetaModel);
				
	
			codes2.put("0010", oneRegisterEventTypeData);
		button01.put("registereventtypes", codes2);
			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadSubApplication");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
		button01.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
		GxtComponentMetaNodeModel node11  = new GxtComponentMetaNodeModel(button01);
		
		Map<String, Object> button02 = new HashMap<String, Object>();
	    button02.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());   
	    button02.put("text", "保存");
		GxtComponentMetaNodeModel node22  = new GxtComponentMetaNodeModel(button02);
		
		Map<String, Object> button03 = new HashMap<String, Object>();
	    button03.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());   
	    button03.put("text", "清空");
		GxtComponentMetaNodeModel node33  = new GxtComponentMetaNodeModel(button03);
		
		Map<String, Object> button04 = new HashMap<String, Object>();
	    button04.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());   
	    button04.put("text", "导入");
		GxtComponentMetaNodeModel node44  = new GxtComponentMetaNodeModel(button04);
		
		Map<String, Object> button05 = new HashMap<String, Object>();
	    button05.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());   
	    button05.put("text", "导出");
		GxtComponentMetaNodeModel node55  = new GxtComponentMetaNodeModel(button05);
	    
	   

		List<GxtComponentMetaNodeModel> list = new ArrayList<GxtComponentMetaNodeModel>();
		list.add(node11);
		list.add(node22);
		list.add(node33);
		//list.add(node44);
		//list.add(node55);
		
		Map<String, Object> toolbar=new HashMap<String, Object>();
		toolbar.put("component_model_type_index", ComponentTypeEnum.TOOLBAR_MODEL.ordinal());
		toolbar.put("id", "03_01_toolbarGxtComponent_Organisation");	
		//toolbar.put("add", btn);
		toolbar.put("children", list);
		GxtComponentMetaNodeModel node4=new GxtComponentMetaNodeModel(toolbar, 5, 6);
		
		

		return node4;
}
private GxtComponentMetaNodeModel getSumFormPanelGxtComponentMetaNodeModel() {
	//创建提交和取消按钮
	Map<String, Object> btnSubmit=new HashMap<String, Object>();
//	btnSubmit.put("component_model_type", ComponentTypeEnum.BUTTON_MODEL);
	//实际创建时，不检查此属性
	btnSubmit.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());
	btnSubmit.put("text", "sumFormPanel确定000000");
	btnSubmit.put("id", "03_01_sumFormPanelGxtComponent_Organisation");
	Map<String,Object> codes2 = new HashMap<String, Object>();
	//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
	/**
	 * 00_01_02为特征码
	 * 或者是 控制器的唯一标识
	 */
			Map<String,Object> oneRegisterEventTypeData = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				//eventStructureMetaModel.setControllerId("shortcutController02");
				eventStructureMetaModel.setRootControllerId("windowController2");
				//eventStructureMetaModel.setResponseModeId("00_02_02");
			oneRegisterEventTypeData.put("eventstructuremetamodel", eventStructureMetaModel);
			oneRegisterEventTypeData.put("dispachereventtype", "0007");
	
		codes2.put("0302", oneRegisterEventTypeData);
	btnSubmit.put("registereventtypes", codes2);
	GxtComponentMetaNodeModel btnSubmit1=new GxtComponentMetaNodeModel(btnSubmit);
	
	Map<String, Object> btnquxiao=new HashMap<String, Object>();
//	btnquxiao.put("component_model_type", ComponentTypeEnum.BUTTON_MODEL);
	//实际创建时，不检查此属性
	btnquxiao.put("component_model_type_index", ComponentTypeEnum.BUTTON_MODEL.ordinal());
	btnquxiao.put("text", "取消");
	GxtComponentMetaNodeModel btn1=new GxtComponentMetaNodeModel(btnquxiao);
	
	List<GxtComponentMetaNodeModel> list1=new ArrayList<GxtComponentMetaNodeModel>();
	list1.add(btnSubmit1);
	list1.add(btn1);
	
	
	
	Map<String, Object> MaxPanel=new HashMap<String, Object>();
//	MaxPanel.put("component_model_type", ComponentTypeEnum.FORMPANEL_MODEL);
	MaxPanel.put("component_model_type_index", ComponentTypeEnum.FORMPANEL_MODEL.ordinal());
	MaxPanel.put("autowidth", true);
	MaxPanel.put("autoheight", true);
	MaxPanel.put("frame", true);
	MaxPanel.put("headervisible", false);
	//TODO MaxPanel.put("addbutton", list1);
	MaxPanel.put("addsubmitbutton", true);
	MaxPanel.put("addresetbutton", true);
	MaxPanel.put("buttonalign", "CENTER");
	MaxPanel.put("layoutindex", ComponentTypeEnum.FORMLAYOUT_MODEL.ordinal());

	GxtComponentMetaNodeModel node5=new GxtComponentMetaNodeModel(MaxPanel);
	
	return node5;
}





private GxtComponentMetaNodeModel getTabPanelGxtComponentMetaNodeModel() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.TABPANEL_MODEL.ordinal());
	//map2.put("headervisible", false);	
	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
	map2.put("width", "800");
	map2.put("id", "04_01_tabPanelGxtComponent_Organisation");
	map2.put("height", "500");

	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}


private GxtComponentMetaNodeModel getTabItemGxtComponentMetaNodeModel1() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.TABITEM_MODEL.ordinal());
	map2.put("id", "05_01_tabItemGxtComponent_Organisation");
	map2.put("text", "基本信息");
	map2.put("layoutindex", ComponentTypeEnum.COLUMNLAYOUT_MODEL.ordinal());
	//map2.put("headervisible", false);	
	map2.put("height", 400);	
	//map2.put("headervisible", false);	
	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}




private GxtComponentMetaNodeModel getTabItemGxtComponentMetaNodeModel2() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.TABITEM_MODEL.ordinal());
	map2.put("id", "05_02_tabItemGxtComponent_Organisation");
	map2.put("text", "联系方式");
	//map2.put("headervisible", false);	
	map2.put("height", 400);	
	//map2.put("headervisible", false);	

	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}




private GxtComponentMetaNodeModel getContentPanelGxtComponentMetaNodeModel1() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.CONTENTPANEL_MODEL.ordinal());
	map2.put("headervisible", false);	
	map2.put("layoutindex", ComponentTypeEnum.FORMLAYOUT_MODEL.ordinal());
	map2.put("id", "06_01_contentPanelGxtComponent_Organisation");	
	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");
	map2.put("layoutdatainparentcontainer", ".5");
	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}
private GxtComponentMetaNodeModel getContentPanelGxtComponentMetaNodeModel2() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.CONTENTPANEL_MODEL.ordinal());
	map2.put("headervisible", false);	
	map2.put("id", "06_02_contentPanelGxtComponent_Organisation");	
	map2.put("layoutindex", ComponentTypeEnum.FORMLAYOUT_MODEL.ordinal());
	map2.put("layoutdatainparentcontainer", ".5");
	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}



private GxtComponentMetaNodeModel getContentPanelGxtComponentMetaNodeModel3() {
	Map<String, Object> map2=new HashMap<String, Object>();
	//map2.put("component_model_type", ComponentTypeEnum.CONTENTPANEL_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.CONTENTPANEL_MODEL.ordinal());
	map2.put("headervisible", false);	
	map2.put("id", "06_03_contentPanelGxtComponent_Organisation");	
	map2.put("layoutindex", ComponentTypeEnum.FORMLAYOUT_MODEL.ordinal());
	
	map2.put("title", "Rpc===dataload----AppEvents.DESKTOP_INIT_FOR_LOGGED_IN_USER");	
	GxtComponentMetaNodeModel node2=new GxtComponentMetaNodeModel(map2);
	return node2;
}






//名称 
private GxtComponentMetaNodeModel getTextFieldGxtComponentMetaNodeModelnode7_1() {
	
	Map<String, Object> TextFieldGxtComponent = new HashMap<String, Object>();
	TextFieldGxtComponent.put("component_model_type_index", ComponentTypeEnum.TEXTFIELD_MODEL.ordinal());

			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadTextFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
			TextFieldGxtComponent.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
			TextFieldGxtComponent.put("id", "07_01.Organisation.name");
			TextFieldGxtComponent.put("width", "400");
			TextFieldGxtComponent.put("title", "bbbbbbbbbbbbbbb");
			TextFieldGxtComponent.put("fieldlabel", "名称");
			TextFieldGxtComponent.put("name", "textField01");
			TextFieldGxtComponent.put("emptytext", "afjooanfaof");
			TextFieldGxtComponent.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
		//codes1.add("0002");
	//id.put("registereventtypes", codes2);
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(TextFieldGxtComponent,10,11);
	return node10;
}





//职位

private GxtComponentMetaNodeModel getComboBoxGxtComponentMetaNodeModelnode7_1() {

	Map<String, Object> type = new HashMap<String, Object>();
	type.put("component_model_type_index", ComponentTypeEnum.COMBOBOX_MODEL.ordinal());
	type.put("fieldlabel", "职位");
	type.put("id", "06_06.UnitConversionRate.conversionStyle");
	//type.put("dataload", "xxx");
	type.put("typeahead", true);
	type.put("emptytext", "===请选择===");
	type.put("loadingtext", "数据加载中,请稍等。。。。。。");
	type.put("allowblank", false);
	type.put("name", "comboBox");
	BaseModel gxtToSeamServiceParameter = new BaseModel();
	gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
	gxtToSeamServiceParameter.set("serviceMethodName", "loadComboBoxData");
	BaseModel[] methodArguments2 = new BaseModel[1];
	methodArguments2[0] = new BaseModel();
	gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
	type.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);

	
	GxtComponentMetaNodeModel node11  = new GxtComponentMetaNodeModel(type,12,13);
	return node11;
}





//具体地址
private GxtComponentMetaNodeModel getTextFieldGxtComponentMetaNodeModelnode7_2() {
	
	Map<String, Object> TextFieldGxtComponent = new HashMap<String, Object>();
	TextFieldGxtComponent.put("component_model_type_index", ComponentTypeEnum.TEXTFIELD_MODEL.ordinal());

			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadTextFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
			TextFieldGxtComponent.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
			TextFieldGxtComponent.put("id", "06_03.UnitConversionRate.normUnits");
			TextFieldGxtComponent.put("width", "400");
			TextFieldGxtComponent.put("title", "bbbbbbbbbbbbbbb");
			TextFieldGxtComponent.put("fieldlabel", "名称");
			TextFieldGxtComponent.put("name", "textField01");
			TextFieldGxtComponent.put("emptytext", "afjooanfaof");
			TextFieldGxtComponent.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
		//codes1.add("0002");
	//id.put("registereventtypes", codes2);
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(TextFieldGxtComponent,10,11);
	return node10;
}





/**
 * 
 * 描述信息
 */
private GxtComponentMetaNodeModel getTextAreaGxtComponentMetaNodeModelnode7_1() {
	
	Map<String, Object> id = new HashMap<String, Object>();
	id.put("component_model_type_index", ComponentTypeEnum.TEXTAREA_MODEL.ordinal());
	
			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadTextFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
	id.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
	id.put("id", "07_01.UnitConversionRate.description");
	id.put("width", "400");
	id.put("height", 50);
	id.put("title", "bbbbbbbbbbbbbbb");
	id.put("fieldlabel", "描述信息");
	id.put("label", "编号Area_label");
	id.put("name", "textArea01");
	id.put("emptytext", "afjooanfaof");
	id.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
	
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(id,10,11);
	return node10;
	
}





//简称
private GxtComponentMetaNodeModel getTextFieldGxtComponentMetaNodeModelnode7_3() {
	
	Map<String, Object> TextFieldGxtComponent = new HashMap<String, Object>();
	TextFieldGxtComponent.put("component_model_type_index", ComponentTypeEnum.TEXTFIELD_MODEL.ordinal());

			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadTextFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
			TextFieldGxtComponent.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
			TextFieldGxtComponent.put("id", "06_03.UnitConversionRate.normUnits");
			TextFieldGxtComponent.put("width", "400");
			TextFieldGxtComponent.put("title", "bbbbbbbbbbbbbbb");
			TextFieldGxtComponent.put("fieldlabel", "简称");
			TextFieldGxtComponent.put("name", "textField01");
			TextFieldGxtComponent.put("emptytext", "afjooanfaof");
			TextFieldGxtComponent.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
		//codes1.add("0002");
	//id.put("registereventtypes", codes2);
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(TextFieldGxtComponent,10,11);
	return node10;
}






//上级组织 

private GxtComponentMetaNodeModel getComboBoxGxtComponentMetaNodeModelnode7_2() {

	Map<String, Object> type = new HashMap<String, Object>();
	type.put("component_model_type_index", ComponentTypeEnum.COMBOBOX_MODEL.ordinal());
	type.put("fieldlabel", "上级组织");
	type.put("id", "06_06.UnitConversionRate.conversionStyle");
	//type.put("dataload", "xxx");
	type.put("typeahead", true);
	type.put("emptytext", "===请选择===");
	type.put("loadingtext", "数据加载中,请稍等。。。。。。");
	type.put("allowblank", false);
	type.put("name", "comboBox");
	BaseModel gxtToSeamServiceParameter = new BaseModel();
	gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
	gxtToSeamServiceParameter.set("serviceMethodName", "loadComboBoxData");
	BaseModel[] methodArguments2 = new BaseModel[1];
	methodArguments2[0] = new BaseModel();
	gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
	type.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);

	
	GxtComponentMetaNodeModel node11  = new GxtComponentMetaNodeModel(type,12,13);
	return node11;
}


/**
 * 成立日期
 */
private GxtComponentMetaNodeModel getDateFieldGxtComponentMetaNodeModel1() {
	//编号
	Map<String, Object> id = new HashMap<String, Object>();
	id.put("component_model_type_index", ComponentTypeEnum.DATEFIELD_MODEL.ordinal());
	//id.put("dataload", "xxx");
			/*GxtToSeamServiceParameter gxtToSeamServiceParameter = new GxtToSeamServiceParameter();
			gxtToSeamServiceParameter.setServiceComponentName("com.test.server.business.PersonService");
			gxtToSeamServiceParameter.setServiceMethodName("loadTextFieldData");
		//	gxtToSeamServiceParameter.setServiceMethodName("getList2");
		//	gxtToSeamServiceParameter.setServiceMethodName("getEnums");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.setMethodArguments(methodArguments2 );*/
			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadDateFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
	id.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
	id.put ( "id" , "06_10.CargoSpace.effectiveDate" ); 
	id.put("width", "400");
	id.put("title", "bbbbbbbbbbbbbbb");
	id.put("fieldlabel", "成立日期");
	id.put("name", "dateField01");
	id.put("emptytext", "Rpc____emptytext");
	id.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
		//codes1.add("0002");
	//id.put("registereventtypes", codes2);
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(id,10,11);
	return node10;
	
}


/**
 * 
 * 备注信息
 */
private GxtComponentMetaNodeModel getTextAreaGxtComponentMetaNodeModelnode7_2() {
	
	Map<String, Object> id = new HashMap<String, Object>();
	id.put("component_model_type_index", ComponentTypeEnum.TEXTAREA_MODEL.ordinal());
	
			BaseModel gxtToSeamServiceParameter = new BaseModel();
			gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
			gxtToSeamServiceParameter.set("serviceMethodName", "loadTextFieldData");
			BaseModel[] methodArguments2 = new BaseModel[1];
			methodArguments2[0] = new BaseModel();
			gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
	id.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
	id.put("id", "07_01.UnitConversionRate.description");
	id.put("width", "400");
	id.put("height", 50);
	id.put("title", "bbbbbbbbbbbbbbb");
	id.put("fieldlabel", "备注信息");
	id.put("label", "编号Area_label");
	id.put("name", "textArea01");
	id.put("emptytext", "afjooanfaof");
	id.put("allowblank", false);
		Map<String,Object> codes2 = new HashMap<String, Object>();
		//添加需要监听的事件类型，指定由某一个控制器响应，控制器内部应该如何响应（附加参数和数据）
		/**
		 * 00_01_02为特征码
		 * 或者是 控制器的唯一标识
		 */
			Map<String,Object> subMap = new HashMap<String, Object>();
				EventStructureMetaModel eventStructureMetaModel = new EventStructureMetaModel();
				eventStructureMetaModel.setControllerId("textFieldController01");
				eventStructureMetaModel.setResponseModeId("00_01_02");
			subMap.put("eventstructuremetamodel", eventStructureMetaModel);
		codes2.put("0301", subMap);
	
	GxtComponentMetaNodeModel node10  = new GxtComponentMetaNodeModel(id,10,11);
	return node10;
	
}





private GxtComponentMetaNodeModel getGridSetModuleGxtComponentMetaNodeModel() {
	Map<String, Object> map2 = new HashMap<String, Object>();
//	map2.put("component_model_type", ComponentTypeEnum.GRIDSETMODULES_MODEL);
	map2.put("component_model_type_index", ComponentTypeEnum.GRIDSETMODULES_MODEL.ordinal());
	map2.put("autowidth", true);
	map2.put("autoheight", true);
	map2.put("frame", true);
	map2.put("headervisible", false);
	
	Map<String,Object> oneDispacherEventTypeData = new HashMap<String, Object>();
	EventStructureMetaModel subEventStructureMetaModel = new EventStructureMetaModel();
	subEventStructureMetaModel.setControllerId("dataLoadController01");
	subEventStructureMetaModel.setRootControllerId("1_1_windowController_Country");
	oneDispacherEventTypeData.put("eventstructuremetamodel", subEventStructureMetaModel);
	
	
	Map<String,Object> dispacherEventTypeDatas = new HashMap<String, Object>();
	dispacherEventTypeDatas.put("0007", oneDispacherEventTypeData);
	map2.put("dispachereventtypes", dispacherEventTypeDatas);
		
		//可编辑表格
		Map<String, Object> map3 = new HashMap<String, Object>();
		//实际中，此属性不起作用
//		map3.put("component_model_type", ComponentTypeEnum.GRIDMODULE_MODEL);
		map3.put("component_model_type_index", ComponentTypeEnum.GRIDMODULE_MODEL.ordinal());
		map3.put("version",1);//可编辑表格
		map3.put("hight", 100);
		//map3.put("width", 500);
		map3.put("headervisible",false );
		map3.put("rownumber", true);
		map3.put("id", "04_01_gridSetModuleGxtComponent_Country");
				List<ModelData> columnConfigs = new ArrayList<ModelData>();		
				columnConfigs.add(new GridColumnConfigModel("name","联系方式类型",100));
				columnConfigs.add(new GridColumnConfigModel("abbreviation","联系方式",100));
				columnConfigs.add(new GridColumnConfigModel("locationType","联系方式用途",100));
				columnConfigs.add(new GridColumnConfigModel("description","描述信息",100));
			
				
		map3.put("columnconfigload", columnConfigs);
		
				
				
				BaseModel gxtToSeamServiceParameter = new BaseModel();
				gxtToSeamServiceParameter.set("serviceComponentName", "com.test.server.business.PersonService");
				gxtToSeamServiceParameter.set("serviceMethodName", "loadEditorableGrid");
				BaseModel[] methodArguments2 = new BaseModel[1];
				methodArguments2[0] = new BaseModel();
				gxtToSeamServiceParameter.set("methodArguments",methodArguments2 );
		map3.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter);
		
		//###################3
		Map<String, Object> simpleComboBox01 = new HashMap<String, Object>();
	    simpleComboBox01.put("component_model_type_index", ComponentTypeEnum.SIMPLECOMBOBOX_MODEL.ordinal()); 
			    BaseModel gxtToSeamServiceParameter_comboBox1 = new BaseModel();
				gxtToSeamServiceParameter_comboBox1.set("serviceComponentName", "com.test.server.business.PersonService");
				gxtToSeamServiceParameter_comboBox1.set("serviceMethodName", "loadSimpleComboBoxData");
				gxtToSeamServiceParameter_comboBox1.set("methodArguments",methodArguments2 );
		simpleComboBox01.put("gxttoseamserviceparametermodel", gxtToSeamServiceParameter_comboBox1);
	    simpleComboBox01.put("id", "locationType");
		GxtComponentMetaNodeModel node22  = new GxtComponentMetaNodeModel(simpleComboBox01);
		
		List<GxtComponentMetaNodeModel> simpleComboBoxs = new ArrayList<GxtComponentMetaNodeModel>();
		simpleComboBoxs.add(node22);
		
		map3.put("children", simpleComboBoxs);
		//#########################
		map3.put("dataload", gxtToSeamServiceParameter);
		GxtComponentMetaNodeModel node3 = new GxtComponentMetaNodeModel(map3);
	
	List<GxtComponentMetaNodeModel> list = new ArrayList<GxtComponentMetaNodeModel>();
	list.add(node3);
	map2.put("gridlist", list);
	GxtComponentMetaNodeModel node2 = new GxtComponentMetaNodeModel(map2);
	return node2;
}


}
